package com.project.server.mapper.broadroom;

import com.project.server.domain.broadroom.TBroadroomBook;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 会议室预约Mapper接口
 *
 * @author project
 */
public interface TBroadroomBookMapper {


    /**
     * 根据会议室名称查询预约信息
     *
     * @param broadroomName 会议室名称
     * @return 会议室预约集合
     */
    List<TBroadroomBook> selectTBroadroomBookByBroadroomName(String broadroomName);

    /**
     * 查询会议室预约
     *
     * @param broadroomBookId 会议室预约ID
     * @return 会议室预约
     */
    public TBroadroomBook selectTBroadroomBookById(Long broadroomBookId);

    /**
     *根据预约人电话号码查询预约信息
     *
     * @return
     */
    public List<TBroadroomBook> selectTBroadroomBookByPhone(TBroadroomBook tBroadroomBook);

    /**
     * 查询会议室预约列表
     *
     * @param tBroadroomBook 会议室预约
     * @return 会议室预约集合
     */
    public List<TBroadroomBook> selectTBroadroomBookList(TBroadroomBook tBroadroomBook);

    /**
     * 新增会议室预约
     *
     * @param tBroadroomBook 会议室预约
     * @return 结果
     */
    public int insertTBroadroomBook(TBroadroomBook tBroadroomBook);

    /**
     * 修改会议室预约
     *
     * @param tBroadroomBook 会议室预约
     * @return 结果
     */
    public int updateTBroadroomBook(TBroadroomBook tBroadroomBook);

    /**
     * 修改预约状态
     *
     * @param broadroomBookId 会议室预约ID
     * @param bookStatus 预约状态
     * @return 结果
     */
    public int updateBookStatus(@Param("broadroomBookId") Long broadroomBookId, @Param("bookStatus") String bookStatus);

    /**
     * 删除会议室预约
     *
     * @param broadroomBookId 会议室预约ID
     * @return 结果
     */
    public int deleteTBroadroomBookById(Long broadroomBookId);

    /**
     * 批量删除会议室预约
     *
     * @param broadroomBookIds 需要删除的数据ID
     * @return 结果
     */
    public int deleteTBroadroomBookByIds(Long[] broadroomBookIds);

    /**
     *  根据选择时间查询会议室预约信息
     *
     * @param tBroadroomBook
     * @return 预约列表
     */
    List<TBroadroomBook> selectTBroadroomBookBybookStart(TBroadroomBook tBroadroomBook);
}
